*** Esoteric beliefs and CAM impact SARS-CoV-2 immunization drivers, uptake and pediatric immunization views in Germany

*** Sebastian Jäckle & James K. Timmis

* version 01.08.2024

clear all

* install additional modules
/*
ssc install asdoc, replace
ssc install tabcount, replace
ssc install alphawgt, replace
ssc install mdesc, replace
ssc install egenmore, replace
net install grc1leg,from( http://www.stata.com/users/vwiggins/) 
ssc install g538schemes, replace
ssc install blindschemes, replace
ssc install mplotoffset, replace
ssc install coefplot, replace
*/


 cd  "YOURPATH\replication"

* Read data
use "data\PPD_July_2022_reduced.dta", replace


*** Calculate Raking Weights based on gender, agegroup, state and highest education
 egen age_group_raking = cut(v_125), at(18 , 31, 46, 61,  110)	 label 
 table age_group_raking
 label define age_group_raking 0 "18-30" 1 "31-45" 2 "46-60" 3 "> 60", modify
 label values age_group_raking age_group_raking

* non-binary are coded as female for the raking
 gen male_2 = v_370
 replace male_2 = 2 if v_370 == 3 
	
* highest school leaving certificate
 	recode v_20 (1 2 9=1) (3 =2) (4 5 10 =3), gen(edu_3)
 	label define edu_3 1 "low" 2 "middle" 3 "high", modify
 	label values edu_3 edu_3
 	label variable edu_3					"educational attainment (low/middle/high)"
	
* Recode Sunday question for raking (CDU and CSU together)
 recode v_1143 (2 8 = 1) (3 = 2) (4 = 3) (5 = 4) (6 = 5) (7 = 6)  (10/99 = 7), gen(sonntagsfrage)
 label define sonntagsfrage 1 "CDU/CSU" 2 "SPD" 3 "Grüne" 4 "FDP" 5 "Linke" 6 "AfD" 7 "Sonstige", modify
 label value sonntagsfrage sonntagsfrage

 gen bundesland = v_19
 replace bundesland =. if v_19 == 0
 tab bundesland

* generate base weight = 1  
 gen wt = 1

 	* Vorgehen nach : https://www.stata-press.com/books/sw-preview.pdf ab S. 58
 	* wichtig! nicht die exakten Populationsgrößen verwenden, sondern gerundet auf tausend (dabei auf gleiche Anzahl an totals achten!)
 	* Mit zu großen Zahlen kommt svycal nicht zurecht


	* official data
 	#delimit ; 
 	svycal rake  i.bundesland i.age_group_raking  i.male_2 i.sonntagsfrage [pw=wt] , gen(rake_wt_2) ll(0.1) ul(10) tolerance(0.01) 
 	totals( _cons=61732
 			1.bundesland  =  7831
 			2.bundesland  =  9602
 			3.bundesland  =  2482
 			4.bundesland  =  2070
 			5.bundesland  =  472
 			6.bundesland  =  1293
 			7.bundesland  =  4422
 			8.bundesland  =  1332
 			9.bundesland  =  6145
 			10.bundesland  =  13104
 			11.bundesland  =  3091
 			12.bundesland  =  760
 			13.bundesland  =  3298
 			14.bundesland  =  1807
 			15.bundesland  =  2279
 			16.bundesland  =  1742
 			0.age_group_raking  =  9782
 			1.age_group_raking  =  12632
 			2.age_group_raking  =  16556
 			3.age_group_raking  =  22761
 			1.male_2  =  29870
 			2.male_2  =  31862
 			1.sonntagsfrage  =  16348
 			2.sonntagsfrage  =  12300
 			3.sonntagsfrage  =  14946
 			4.sonntagsfrage  =  4359
 			5.sonntagsfrage  =  2958
 			6.sonntagsfrage  =  6228
 			7.sonntagsfrage  =  4593
 			)	;
 #delimit cr	

 rename rake_wt_2 gewicht3

 label variable gewicht3 "Raking with state, age group, gender and voting intention"


 
 *** Label variables

* Sunday Question / Voting intention 
label define sonntagsfrage 1 "CDU/CSU" 2 "SPD" 3 "Greens" 4 "FDP" 5 "Left-Party" 6 "AfD" 7 "Others", modify
label value sonntagsfrage sonntagsfrage
label variable sonntagsfrage "Voting intention"

* Education
 	label variable edu_3					"Educational attainment"

* Solidarity
gen solidarity_1 = v_1295
label variable solidarity_1 "Those who pay a lot of taxes are already doing enough for society."
gen solidarity_2 = v_1296
label variable solidarity_2 "Society depends on the voluntary commitment of the population."
gen solidarity_3 = v_1297
label variable solidarity_3 "It is more important to work for the good of the community than for your own good."
gen solidarity_4 = v_1298
label variable solidarity_4 "If a stranger is in need of my support, I try to give it to them."
gen solidarity_5 = v_1300
label variable solidarity_5 "Important matters take precedence, even when free time beckons."
label define solidarity 1 "completely disagree" 2 "rather disagree" 3 "neutral" 4 "rather agree" 5 "completely agree"
label values solidarity_* solidarity

* test solidarity index
pwcorr solidarity_*
factor solidarity_*
	rotate
	estat kmo
	alphawgt solidarity_* [aweight=gewicht3], item

* --> solidarity index including solidarity_1 - solidarity_4 but not solidarity_5

* reverse solidarity_1
gen solidarity_1_rev = 6-solidarity_1

* calculate solidarity index
gen solidarity_index = (((solidarity_1_rev + solidarity_2 + solidarity_3 + solidarity_4)/4)-1)/4
label variable solidarity_index "Solidarity"

* Attitudes towards different school systems
gen school_system_1 = (v_1301 - 1)/4
label variable school_system_1 "Public/State schools"
gen school_system_2 = (v_1302 - 1)/4
label variable school_system_2 "Private schools"
gen school_system_3 = (v_1303 - 1)/4
label variable school_system_3 "Waldorf education"
label define school_system 0 "0 = very negative"  1 "1 = very positive"
label values school_system_* school_system

* Attitudes towards different medical systems
gen medical_system_1 = (v_1415 - 1)/4
label variable medical_system_1 "Mainstream medicine"
gen medical_system_2 = (v_1416 - 1)/4
label variable medical_system_2 "Homeopathy"
gen medical_system_3 = (v_1417 - 1)/4
label variable medical_system_3 "Physiotherapy"
gen medical_system_4 = (v_1418 - 1)/4
label variable medical_system_4 "Acupuncture and acupressure"
label define medical_system 0 "0 = very negative"  1 "1 = very positive"
label values medical_system_* medical_system

* left-right 0-1
gen left_right = (v_773 -1)/10
label define left_right 0 "left" 1 "right"
label value left_right left_right
label variable left_right "Left = 0 / Right = 1"

* GAL-TAN
gen GAL_TAN = (v_774 -1)/10
label define GAL_TAN 0 "GAL" 1 "TAN"
label value GAL_TAN GAL_TAN
label variable GAL_TAN "GAL = 0 / TAN = 1"

* Big-5
			* Big Five Inventory (BFI-10)
			*Autor/in: Rammstedt, B., Kemper, C. J., Klein, M. C., Beierlein, C., & Kovaleva, A.
			* In ZIS seit: 2014
			* DOI: https://doi.org/10.6102/zis76
			
			* Auswertungshinweise: Um Messwerte für die individuelle Ausprägung der Befragungsperson auf den fünf Persönlichkeitsdimensionen zu erhalten, 
			* werden pro Dimension die Antworten auf den beiden Items gemittelt. Hierzu wird zunächst das jeweils negativ gepolte Item rekodiert (Items 1, 3, 4, 5 und 7) 
			* und anschließend pro Dimension der Mittelwert aus dem rekodierten und dem nicht rekodierten Item gebildet. 
			* Der Wertebereich der fünf Dimensionen liegt dann jeweils zwischen 1 und 5 (für Referenzwerte siehe Tabelle 8 - Tabelle 12 oder Rammstedt, 2007).
gen big_5_1 = v_1280
label variable big_5_1 "I see myself as someone who is reserved."
gen big_5_2 = v_1281
label variable big_5_2 "I see myself as someone who is generally trusting."
gen big_5_3 = v_1282
label variable big_5_3 "I see myself as someone who tends to be lazy."
gen big_5_4 = v_1283
label variable big_5_4 "I see myself as someone who is relaxed, handles stress well."
gen big_5_5 = v_1284
label variable big_5_5 "I see myself as someone who has few artistic interests."
gen big_5_6 = v_1285
label variable big_5_6 "I see myself as someone who is outgoing, sociable."
gen big_5_7 = v_1286
label variable big_5_7 "I see myself as someone who tends to find fault with others."
gen big_5_8 = v_1287
label variable big_5_8 "I see myself as someone who does a thorough job."
gen big_5_9 = v_1288
label variable big_5_9 "I see myself as someone who gets nervous easily."
gen big_5_10 = v_1289
label variable big_5_10 "I see myself as someone who has an active imagination."
label define big_5 1 "does not apply at all" 5 "fully applies"
label values big_5_* big_5

	* recode negative poled items
	gen big_5_1_recode = 6 - big_5_1
	gen big_5_3_recode = 6 - big_5_3
	gen big_5_4_recode = 6 - big_5_4
	gen big_5_5_recode = 6 - big_5_5
	gen big_5_7_recode = 6 - big_5_7

	* Means for Big-5 Factors
		* Extraversion
		gen big_5_extraversion = (((big_5_1_recode + big_5_6)/2)-1)/4
		* Agreeableness (Verträglichkeit)
		gen big_5_agreeableness = (((big_5_2 + big_5_7_recode)/2)-1)/4
		* Conscientiousness (Gewissenhaftigkeit)
		gen big_5_conscientiousness = (((big_5_3_recode + big_5_8)/2)-1)/4
		* Neuroticism
		gen big_5_neuroticism = (((big_5_4_recode + big_5_9)/2)-1)/4
		* Openness for experience
		gen big_5_openness = (((big_5_5_recode + big_5_10)/2)-1)/4
		
		label variable big_5_extraversion "Extraversion (Big 5)"
		label variable big_5_neuroticism "Neuroticism (Big 5)"
		label variable big_5_openness "Openness (Big 5)"
		label variable big_5_conscientiousness "Conscientiousness (Big 5)"
		label variable big_5_agreeableness "Agreeableness (Big 5)"
		
		
* Covid-19 Vaccination status
gen vacc_status = v_1133
label variable vacc_status "SARS-CoV-2 vaccination status"
label define vacc_status 1 "not vaccinated" 2 "one vaccination received" 3 "two vaccinations received" 4 "three vaccinations received" 5 "four vaccinations received"
label value vacc_status vacc_status	

gen vacc_04 = vacc_status - 1
label variable vacc_04 "# SARS-CoV-2 vaccine doses"
label define vacc_04 0 "not vaccinated" 1 "one vaccination received" 2 "two vaccinations received" 3 "three vaccinations received" 4 "four vaccinations received"
label value vacc_04 vacc_04	
	
	* Reason for getting vaccinated
gen vacc_reason_1 = (v_1335 -1) /4
label variable vacc_reason_1 "Protecting self"
gen vacc_reason_2 = (v_1336 - 1)/4
label variable vacc_reason_2 "Protecting others"
gen vacc_reason_3 = (v_1337 - 1)/4
label variable vacc_reason_3 "Participation in public events"
gen vacc_reason_4 = (v_1338 - 1)/4
label variable vacc_reason_4 "Vocational mandates"
gen vacc_reason_5 = (v_1339 - 1)/4
label variable vacc_reason_5 "Medical advice/recommendation of the Permanent Vaccination Commission (STIKO)"
gen vacc_reason_6 = (v_1340 - 1)/4
label variable vacc_reason_6 "Peer pressure"
label define vacc_reason 0 "not at all important"  1 "very important"
label value vacc_reason_* vacc_reason

* How useful do you consider routine pediatric immunization, e.g. against measles/mumps/rubella (MMR)?  
gen child_vaccinations = (v_1372 - 1) /3
label variable child_vaccinations "How useful do you consider routine pediatric immunization, e.g. against measles/mumps/rubella (MMR)?"
label define child_vaccinations 0 "not at all meaningful"  1 "very meaningful"
label values child_vaccinations* child_vaccinations 

* Voting intention (Sonntagsfrage)
gen voting_intention_all = v_1143
gen voting_intention_short = sonntagsfrage
label values voting_intention_short sonntagsfrage

* gender including non-binary
	gen gender = v_370

	* gender (including non-binary)
	label define gender 1 "male" 2 "female" 3 "non-binary" 
	label values gender gender	
	label variable gender "Gender"


* Household income
recode v_1131 (1=5) (2=4) (3=3) (4=2) (5=1) (8 = 6), gen(hh_income)
label define hh_income 1 "I find it very difficult to make ends meet" 2 "I find it somewhat difficult to make ends meet" 3 "I can make ends meet" 4 "I can live somewhat comfortably on the income" 5 "I can live very comfortably on the income" 6 "does not apply (no own household income)"
label value hh_income hh_income

* Religious denomination
gen religion = v_1311
label variable religion "Religious denomination"
label define religion 1 "non-denominational" 2 "Roman-Catholic" 3 "Protestant" 4 "Evangelical Free Church" 5 "Orthodox"  6 "Jewish" 7 "Muslim" 8 "Other"
label value religion religion

* Bundesland
label define bundesland 1 "Baden-Wuerttemberg" 2 "Bavaria" 3 "Berlin" 4 "Brandenburg" 5 "Bremen" 6 "Hamburg" 7 "Hesse" 8 "Mecklenburg-Vorpommern" 9 "Lower Saxony" 10 "North Rhine-Westphalia" 11 "Rhineland Palatinate" 12 "Saarland" 13 "Saxony" 14 "Saxony-Anhalt"  15 "Schleswig Holstein" 16 "Thuringia" 17 "Foreign country"
label values bundesland bundesland

* age
gen age = v_125

* age group raking
replace age_group_r = age_group_r + 1
label define age_group_r 1 "18-30" 2 "31-45" 3 "46-60" 4 "> 60"
label value age_group_r age_group_r
label variable age_group_r "Age group"

* weight(gewicht3) for youth = 1 and for bundesland = foreign = 1
replace gewicht3 = 1 if age < 18
replace gewicht3 = 1 if bundesland == 17

* for crosscheck full basic immunisation
recode vacc_04 (2/4 = 1) (0/1 = 0), gen(basic_vacc)
label variable basic_vacc "Basic immunization (2 or more doses)"

********** Missings

* Table S2: Missing values – item non-response 
asdoc mdesc vacc_04 basic_vacc vacc_reason_* child_vaccinations medical_system_1 medical_system_2 school_system_3 religion left_right GAL_TAN sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  bundesland gender age_group_r edu_3 hh_inc if age > 17, replace save(tables\Table S2.rtf) title(Table S2: Missing values - item non-response)

*** Generate filter variables for listwise deletion
* Filter for listwise deletion in Analysis I and Analysis III
gen filter_1 = 1
replace filter_1 = 0 if child_vaccinations == .
replace filter_1 = 0 if vacc_04 == .
replace filter_1 = 0 if age_group_r == .
replace filter_1 = 0 if gender == .
replace filter_1 = 0 if left_right == .
replace filter_1 = 0 if GAL_TAN == .
replace filter_1 = 0 if solidarity_index == .
replace filter_1 = 0 if big_5_e == .
replace filter_1 = 0 if big_5_n == .
replace filter_1 = 0 if big_5_a == .
replace filter_1 = 0 if big_5_c == .
replace filter_1 = 0 if big_5_o == .
replace filter_1 = 0 if sonntagsfrage == .
replace filter_1 = 0 if medical_system_1 == .
replace filter_1 = 0 if medical_system_2 == .
replace filter_1 = 0 if school_system_3 == .
replace filter_1 = 0 if religion == .
replace filter_1 = 0 if bundesland == .
replace filter_1 = 0 if edu_3 == .
replace filter_1 = 0 if hh_inc == .

* Filter for listwise deletion in Analysis II 
gen filter_2 = 1
replace filter_2 = 0 if vacc_reason_1 == .
replace filter_2 = 0 if vacc_reason_2 == .
replace filter_2 = 0 if vacc_reason_3 == .
replace filter_2 = 0 if vacc_reason_4 == .
replace filter_2 = 0 if vacc_reason_5 == .
replace filter_2 = 0 if vacc_reason_6 == .
replace filter_2 = 0 if age_group_r == .
replace filter_2 = 0 if gender == .
replace filter_2 = 0 if left_right == .
replace filter_2 = 0 if GAL_TAN == .
replace filter_2 = 0 if solidarity_index == .
replace filter_2 = 0 if big_5_e == .
replace filter_2 = 0 if big_5_n == .
replace filter_2 = 0 if big_5_a == .
replace filter_2 = 0 if big_5_c == .
replace filter_2 = 0 if big_5_o == .
replace filter_2 = 0 if sonntagsfrage == .
replace filter_2 = 0 if medical_system_1 == .
replace filter_2 = 0 if medical_system_2 == .
replace filter_2 = 0 if school_system_3 == .
replace filter_2 = 0 if religion == .
replace filter_2 = 0 if bundesland == .
replace filter_2 = 0 if edu_3 == .
replace filter_2 = 0 if hh_inc == .


*** Figure S3: Distribution of main demographic variables in the sample compared to reality
	* Gender (data from Destatis 12411-0013:  Bevölkerung: Bundesländer, Stichtag, Geschlecht Fortschreibung des Bevölkerungsstandes)
	gen		str gender2 	= "male" in 1
		replace gender2 	= "female" in 2
		replace gender2 	= "non-binary" in 3
		
	gen gender_real			= 48.9250541 in 1
		replace gender_real	= 51.0749459 in 2
		replace gender_real	= 0 in 3

	estpost tab gender if filter_1 == 1
	mat gender_survey = e(pct)'	
	svmat gender_survey	
	rename gender_survey1 gender_survey
	replace gender_survey = . if gender_real == .

	label variable gender_real "Official statistics, Dec 2021"
	label variable gender_survey "Survey, Jun/Jul 2022"	
	graph bar (asis) gender_real gender_survey, over(gender2) bar(1, color(gs10) fint(80)) bar(2, color(538b))  legend(col(2) pos(6)) note("N=7,391", ring(0) pos(1)) ytitle("Percent") title("Gender")
	graph save "dump/gender_survey.gph", replace 

	* Age (data from Destatis 12411-0013:  Bevölkerung: Bundesländer, Stichtag, Geschlecht; Fortschreibung des Bevölkerungsstandes)
	gen age2 = _n +17
	replace age2 = . if age2 > 90

	gen age_real = .
	replace age_real = 0.0111418039055486 if age2 == 18
	replace age_real = 0.0114986529869714 if age2 == 19
	replace age_real = 0.0119848447250272 if age2 == 20
	replace age_real = 0.0127466878196854 if age2 == 21
	replace age_real = 0.0130162994378358 if age2 == 22
	replace age_real = 0.0134075274600889 if age2 == 23
	replace age_real = 0.014035285478184 if age2 == 24
	replace age_real = 0.0139619581523964 if age2 == 25
	replace age_real = 0.0137480735720865 if age2 == 26
	replace age_real = 0.0139275503822657 if age2 == 27
	replace age_real = 0.0143372868154311 if age2 == 28
	replace age_real = 0.0145521083480068 if age2 == 29
	replace age_real = 0.0150259899747549 if age2 == 30
	replace age_real = 0.0163484332320248 if age2 == 31
	replace age_real = 0.0161257413004162 if age2 == 32
	replace age_real = 0.0164583449401298 if age2 == 33
	replace age_real = 0.0160947498023932 if age2 == 34
	replace age_real = 0.0157837825526947 if age2 == 35
	replace age_real = 0.0152987439866584 if age2 == 36
	replace age_real = 0.0151791023896391 if age2 == 37
	replace age_real = 0.0151818411731853 if age2 == 38
	replace age_real = 0.0154614853879051 if age2 == 39
	replace age_real = 0.0153166181529601 if age2 == 40
	replace age_real = 0.0153750983889971 if age2 == 41
	replace age_real = 0.0146256086495974 if age2 == 42
	replace age_real = 0.0144086393341354 if age2 == 43
	replace age_real = 0.014254330503281 if age2 == 44
	replace age_real = 0.0139816341499785 if age2 == 45
	replace age_real = 0.0136046045582151 if age2 == 46							
	replace age_real = 0.0137549493602526 if age2 == 47
	replace age_real = 0.0138373146717427 if age2 == 48
	replace age_real = 0.0149401795618566 if age2 == 49
	replace age_real = 0.0163708624278033 if age2 == 50
	replace age_real = 0.0169336680319022 if age2 == 51
	replace age_real = 0.0181318570040749 if age2 == 52
	replace age_real = 0.0189329656059959 if age2 == 53
	replace age_real = 0.0193634591355116 if age2 == 54
	replace age_real = 0.0198132106377524 if age2 == 55
	replace age_real = 0.0198048357259611 if age2 == 56
	replace age_real = 0.0200999901043426 if age2 == 57
	replace age_real = 0.0198443174529774 if age2 == 58
	replace age_real = 0.0191318301207522 if age2 == 59
	replace age_real = 0.0187465985930004 if age2 == 60
	replace age_real = 0.0180294841580471 if age2 == 61
	replace age_real = 0.0174170777424611 if age2 == 62
	replace age_real = 0.0163504945270096 if age2 == 63
	replace age_real = 0.015858392782354 if age2 == 64
	replace age_real = 0.0153056053601742 if age2 == 65
	replace age_real = 0.0147086082056982 if age2 == 66
	replace age_real = 0.0142985834795279 if age2 == 67
	replace age_real = 0.0137215362009887 if age2 == 68
	replace age_real = 0.0135766401367431 if age2 == 69
	replace age_real = 0.0131612387460321 if age2 == 70
	replace age_real = 0.0130163859257373 if age2 == 71
	replace age_real = 0.0124278069270034 if age2 == 72
	replace age_real = 0.0111877001519232 if age2 == 73
	replace age_real = 0.0103634127924111 if age2 == 74
	replace age_real = 0.00885357908197849 if age2 == 75
	replace age_real = 0.00764052860540493 if age2 == 76
	replace age_real = 0.0100166827954591 if age2 == 77
	replace age_real = 0.00996342066281012 if age2 == 78
	replace age_real = 0.00941658649118079 if age2 == 79
	replace age_real = 0.0110886859194021 if age2 == 80
	replace age_real = 0.0112094662737906 if age2 == 81
	replace age_real = 0.0105624791122709 if age2 == 82
	replace age_real = 0.00929123669266517 if age2 == 83
	replace age_real = 0.00810064424117065 if age2 == 84
	replace age_real = 0.00721644959524743 if age2 == 85
	replace age_real = 0.00631370329446111 if age2 == 86
	replace age_real = 0.00523884606976993 if age2 == 87
	replace age_real = 0.00369457575990613 if age2 == 88
	replace age_real = 0.00318010247807297 if age2 == 89
	replace age_real = 0.0122011797958785 if age2 == 90

	gen age_survey = age
	label variable age_real "Official statistics, Dec 2021"
	label variable age_survey "Survey, Jun/Jul 2022"

	twoway bar age_real age2,  lcolor(gs10) fcolor(gs10) || hist age_survey if filter_1 == 1, width(1)  fcolor(none) lcolor(538b) || pcarrowi 0.012 94 0.0118 91  , lcolor(gs6) mcolor(gs6) msize(vsmall) legend(order(1 2 "Survey, June 2022" ) col(2) pos(6)) note("N=7,391", ring(0) pos(1)) ytitle("Density") xtitle("") text(0.0121 96  "90+", color(gs6) size(small)) title("Age")
	graph save "dump/age_survey.gph", replace

	* education (data from Destatis 12211-9012 Allgemeiner Schulabschluss & 12211-9015 Beruflicher Schulabschluss)
	gen			edu2 	= 1 in 1
		replace edu2 	= 2 in 2
		replace edu2 	= 3 in 3
		
	label values edu2 edu_3 
		
	gen edu_real			= 32.68595569 in 1 		// ohne allg. Schulabschluss + Haupt- (Volks-)schulabschluss
		replace edu_real	= 30.23489885 in 2		// polytechnische Oberschule + Realschulabschluss + ohne Angabe
		replace edu_real	= 37.07914546 in 3		// Abitur/Fachabitur

	estpost tab edu_3
	mat edu_survey = e(pct)'	
	svmat edu_survey	
	rename edu_survey1 edu_survey	
	replace edu_survey = . if edu_real == .

	label variable edu_real "Official statistics, Dec 2019"
	label variable edu_survey "Survey, Jun/Jul 2022"	
	*splitvallabels edu2 , length(20)
	graph bar (asis) edu_real edu_survey, over(edu2) bar(1, color(gs10) fint(80)) bar(2, color(538b)) legend(col(2) pos(6)) note("N=7,391", ring(0) pos(1)) ytitle("Percent") title("Education")
	graph save "dump/edu_survey.gph", replace
	 
	* federal state (data from Destatis 12411-0013:  Bevölkerung: Bundesländer, Stichtag, Geschlecht)
	gen		bundesland2 	= _n
		replace bundesland2 = . if bundesland2 > 16
		label values bundesland2 bundesland

	gen bundesland_real = .
	replace bundesland_real = 13.29371947 if bundesland2 == 1
	replace bundesland_real = 15.82356122 if bundesland2 == 2
	replace bundesland_real = 4.410665313 if bundesland2 == 3
	replace bundesland_real = 3.069779952 if bundesland2 == 4
	replace bundesland_real = 0.811429491 if bundesland2 == 5
	replace bundesland_real = 2.217066903 if bundesland2 == 6
	replace bundesland_real = 7.533469557 if bundesland2 == 7
	replace bundesland_real = 1.965747476 if bundesland2 == 8
	replace bundesland_real = 9.623673122 if bundesland2 == 9
	replace bundesland_real = 21.45456218 if bundesland2 == 10
	replace bundesland_real = 4.942643746 if bundesland2 == 11
	replace bundesland_real = 1.203162027 if bundesland2 == 12
	replace bundesland_real = 4.892636442 if bundesland2 == 13
	replace bundesland_real = 2.658832689 if bundesland2 == 14
	replace bundesland_real = 3.526124716 if bundesland2 == 15
	replace bundesland_real = 2.572925698 if bundesland2 == 16
		
	estpost tab bundesland
	mat bundesland_survey = e(pct)'	
	svmat bundesland_survey
	rename bundesland_survey1 bundesland_survey	
	replace bundesland_survey = . if bundesland_real == .

	label variable bundesland_real "Official statistics, Dec 2021"
	label variable bundesland_survey "Survey, Jun/Jul 2022"	
	graph hbar (asis) bundesland_real bundesland_survey, over(bundesland2) bar(1, color(gs10) fint(80)) bar(2, color(538b)) legend(col(2) pos(6)) note("N=7,391", ring(0) pos(1)) ytitle("Percent") title("State")
	graph save "dump/bundesland_survey.gph", replace

	* party (mean of the following four opinion polls: 
			* 28.June-30.June 2022	Forschungsgruppe Wahlen
			* 28.June-02.July 2022 FORSA
			* 04.July-06.July 2022 Infratest Dimap
			* 01.July-05.July 2022	YouGov
			* source: https://www.wahlrecht.de/umfragen/
			
	gen party = sonntagsfrage
	replace party = . if sonntagsfrage > 7

	gen party2 = _n
	replace party2 = . if party2 > 7
	label values party2 sonntagsfrage

	gen party_real = .
	replace party_real = 27 if party2 == 1
	replace party_real = 19.75 if party2 == 2
	replace party_real = 23 if party2 == 3
	replace party_real = 7.25 if party2 == 4
	replace party_real = 4.5 if party2 == 5
	replace party_real = 10.5 if party2 == 6
	replace party_real = 8 if party2 == 7

	estpost tab party
	mat party_survey = e(pct)'	
	svmat party_survey	
	rename party_survey1 party_survey	
	replace party_survey = . if party_real == .

	label variable party_real "Opinion polls 28.Jun - 05.Jul 2022"
	label variable party_survey "Survey, Jun/Jul 2022"	
	graph bar (asis) party_real party_survey, over(party2) bar(1, color(gs10) fint(80)) bar(2, color(538b)) legend(col(2) pos(6)) note("N=7,391", ring(0) pos(1)) ytitle("Percent") title("Party affiliation")
	graph save "dump/party_survey.gph", replace

		graph combine "dump/gender_survey.gph" "dump/age_survey.gph" "dump/edu_survey.gph" "dump/party_survey.gph" ,  rows(2) xsize(5) ysize(5)
		graph save "dump/distribution_survey_a.gph", replace

		graph combine "dump/distribution_survey_a.gph" "dump/bundesland_survey.gph", rows(2) xsize(6) ysize(8)
			gr_edit	.plotregion1.graph2.gmetric_mult = .8
			gr_edit .plotregion1.graph1.plotregion1.graph4.legend.plotregion1.key[1].DragBy 0 -3.017241379310334
			// key[1] reposition
			gr_edit .plotregion1.graph1.plotregion1.graph4.legend.plotregion1.label[1].DragBy 0 -3.879310344827581
			// label[1] reposition
			gr_edit .gmetric_mult = .87
	graph export "fig\Figure S3.emf", replace
	graph export "fig\Figure S3.pdf", replace


** Descriptive statistics

	* Table 2 (has to be composed from the individual parts below)
		** Means and SD
			* reduced dataset (listwise deletion) for Analysis I and III, no weighting: Means and SD
			estpost summarize vacc_04  child_vaccinations school_system_3 medical_system_2 medical_system_1  left_right GAL_TAN solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o   if filter_1 ==1 
			esttab  using "tables\Table 2a_raw.rtf", cells("count mean(fmt(2)) sd(fmt(2))") noobs label replace
	
			* reduced dataset (listwise deletion) for Analysis II, no weighting: Means and SD 
			estpost summarize  vacc_reason_1 vacc_reason_2 vacc_reason_5 vacc_reason_3 vacc_reason_4 vacc_reason_6 if filter_2 ==1
			esttab  using "tables\Table 2b_raw.rtf", cells("count mean(fmt(2)) sd(fmt(2))") noobs label replace
		
			* reduced dataset (listwise deletion) for Analysis I and III,  weighting (gewicht3): Means and SD
			estpost summarize vacc_04  child_vaccinations school_system_3 medical_system_2 medical_system_1  left_right GAL_TAN solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o   if filter_1 ==1 [aweight = gewicht3]
			esttab  using "tables\Table 2a_weighted.rtf", cells("count mean(fmt(2)) sd(fmt(2))") noobs label replace
	
			* reduced dataset (listwise deletion) for Analysis II,  weighting (gewicht3): Means and SD 
			estpost summarize  vacc_reason_1 vacc_reason_2 vacc_reason_5 vacc_reason_3 vacc_reason_4 vacc_reason_6 if filter_2 ==1 [aweight = gewicht3]
			esttab  using "tables\Table 2b_weighted.rtf", cells("count mean(fmt(2)) sd(fmt(2))") noobs label replace
	
		* N and percentages for categorical variables
			* reduced dataset (listwise deletion) for Analysis I and III, no weighting: percentages of categorical variables
			asdoc tab basic_vacc if filter_1 ==1 , replace save(tables\Table 2c.rtf) title(unweighted)
			asdoc tab religion  if filter_1 ==1 , append save(tables\Table 2c.rtf) title(unweighted)
			asdoc tab sonntagsfrage  if filter_1 ==1 , append save(tables\Table 2c.rtf) title(unweighted)
		
			* reduced dataset (listwise deletion) for Analysis I and III,  weighting (gewicht3): percentages of categorical variables
			asdoc tab basic if filter_1 ==1 [aweight = gewicht3] , append save(tables\Table 2c.rtf) title(weighted)
			asdoc tab religion if filter_1 ==1 [aweight = gewicht3] , append save(tables\Table 2c.rtf) title(weighted)
			asdoc tab sonntagsfrage if filter_1 ==1 [aweight = gewicht3] , append save(tables\Table 2c.rtf) title(weighted)
		
	* Table S3: Descriptive statistics – comparison of the original dataset and the final dataset used in the regression models, reduced via listwise deletion (unweighted and weighted data) 
	*			(has to be composed from the individual parts below)
		** Means and SD
			* original dataset/with all cases (without filter_1), no weighting: N, Means and SD 
			estpost summarize vacc_04 vacc_reason_1 vacc_reason_2 vacc_reason_5 vacc_reason_3 vacc_reason_4 vacc_reason_6 child_vaccinations  school_system_3 medical_system_2 medical_system_1  left_right GAL_TAN  solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o 
			esttab using "tables\Table S3a_original.rtf", cells("count mean(fmt(2)) sd(fmt(2))") noobs label replace

			* reduced dataset (listwise deletion) for Analysis I and III, no weighting: Means and SD 
			estpost summarize vacc_04  child_vaccinations  school_system_3 medical_system_2 medical_system_1  left_right GAL_TAN  solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o   if filter_1 ==1 
			esttab  using "tables\Table S3a_raw.rtf", cells("count mean(fmt(2)) sd(fmt(2))") noobs label replace

			* reduced dataset (listwise deletion) for Analysis II, no weighting: Means and SD 
			estpost summarize  vacc_reason_1 vacc_reason_2 vacc_reason_5 vacc_reason_3 vacc_reason_4 vacc_reason_6 if filter_2 ==1
			esttab  using "tables\Table S3b_raw.rtf", cells("count mean(fmt(2)) sd(fmt(2))") noobs label replace
		
			* reduced dataset (listwise deletion) for Analysis I and III, weighting (gewicht3): Means and SD 
			estpost summarize vacc_04  child_vaccinations  school_system_3 medical_system_2 medical_system_1  left_right GAL_TAN  solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o   if filter_1 ==1 [aweight = gewicht3]
			esttab  using "tables\Table S3a_weighted.rtf", cells("count mean(fmt(2)) sd(fmt(2))") noobs label replace

			* reduced dataset (listwise deletion) for Analysis II, weighting (gewicht3): Means and SD 
			estpost summarize  vacc_reason_1 vacc_reason_2 vacc_reason_5 vacc_reason_3 vacc_reason_4 vacc_reason_6 if filter_2 ==1 [aweight = gewicht3]
			esttab  using "tables\Table S3b_weighted.rtf", cells("count mean(fmt(2)) sd(fmt(2))") noobs label replace
		
		* N and percentages for categorical variables
			* original dataset/with all cases (without filter_1) no weighting: percentages of categorical variables 
			asdoc tab basic_vacc, replace save(tables\Table S3c.rtf) title(raw)
			asdoc tab religion, append save(tables\Table S3c.rtf) title(raw) 
			asdoc tab sonntagsfrage, append save(tables\Table S3c.rtf) title(raw)  
			asdoc tab bundesland , append save(tables\Table S3c.rtf) title(raw) 
			asdoc tab gender , append save(tables\Table S3c.rtf) title(raw) 
			asdoc tab age_group_r , append save(tables\Table S3c.rtf) title(raw) 
			asdoc tab edu_3 , append save(tables\Table S3c.rtf) title(raw) 
			asdoc tab hh_inc , append save(tables\Table S3c.rtf) title(raw) 
			
			* reduced dataset (listwise deletion) for Analysis I and III, no weighting: percentages of categorical variables 
			asdoc tab basic_vacc if filter_1 ==1 , append save(tables\Table S3c.rtf) title(unweighted) 
			asdoc tab religion if filter_1 ==1 , append save(tables\Table S3c.rtf) title(unweighted) 
			asdoc tab sonntagsfrage if filter_1 ==1 , append save(tables\Table S3c.rtf) title(unweighted) 
			asdoc tab bundesland if filter_1 ==1 , append save(tables\Table S3c.rtf) title(unweighted) 
			asdoc tab gender if filter_1 ==1 , append save(tables\Table S3c.rtf) title(unweighted) 
			asdoc tab age_group_r if filter_1 ==1 , append save(tables\Table S3c.rtf) title(unweighted) 
			asdoc tab edu_3 if filter_1 ==1 , append save(tables\Table S3c.rtf) title(unweighted) 
			asdoc tab hh_inc if filter_1 ==1 , append save(tables\Table S3c.rtf) title(unweighted) 
		
			* reduced dataset (listwise deletion) for Analysis I and III, weighting (gewicht3): percentages of categorical variables 
			asdoc tab basic_vacc if filter_1 ==1 [aweight = gewicht3] , append save(tables\Table S3c.rtf) title(weighted) 
			asdoc tab religion if filter_1 ==1 [aweight = gewicht3] , append save(tables\Table S3c.rtf) title(weighted) 
			asdoc tab sonntagsfrage if filter_1 ==1 [aweight = gewicht3] , append save(tables\Table S3c.rtf) title(weighted) 
			asdoc tab bundesland if filter_1 ==1 [aweight = gewicht3] , append save(tables\Table S3c.rtf) title(weighted) 
			asdoc tab gender if filter_1 ==1 [aweight = gewicht3] , append save(tables\Table S3c.rtf) title(weighted) 
			asdoc tab age_group_r if filter_1 ==1 [aweight = gewicht3] , append save(tables\Table S3c.rtf) title(weighted) 
			asdoc tab edu_3 if filter_1 ==1 [aweight = gewicht3] , append save(tables\Table S3c.rtf) title(weighted) 
			asdoc tab hh_inc if filter_1 ==1 [aweight = gewicht3] , append save(tables\Table S3c.rtf) title(weighted) 		
	
*** Table S4: (a) Correlations between the main independent variables, and (b) exploratory factor analysis
	* a) Correlation matrix
	asdoc pwcorr school_system_3 medical_system_2 medical_system_1 if filter_1 ==1 [aweight = gewicht3], sig obs replace save(tables\Table S4.rtf) title(Table S4: Correlations - Pearsons r)

*** b) factor analysis
	* Principal factor
	asdoc factor school_system_3 medical_system_2 medical_system_1 if filter_1 ==1 [aweight = gewicht3], append save(tables\Table S4.rtf) title(Table S4: Exploratory factor analysis)
	
	* alternatives not presented
	* Principal components
	factor school_system_3 medical_system_2 medical_system_1 if filter_1 ==1 [aweight = gewicht3], pcf
	* --> passt nicht, weil uniqueness zu hoch (Annahme bei pcf ist, dass uniqueness eigentlich Null ist)
	* Iterated Principal Factor
	factor school_system_3 medical_system_2 medical_system_1 if filter_1 ==1 [aweight = gewicht3], ipf	blanks(.3)
	* ML Factor
	factor school_system_3 medical_system_2 medical_system_1 if filter_1 ==1 [aweight = gewicht3], ml	

*** Table S5: Internal consistency of survey instruments 

	* Solidarity Index --> Supplementary Table 5a)
		asdoc pwcorr solidarity_1 solidarity_2 solidarity_3 solidarity_4 [aweight=gewicht3] if filter_1 == 1, replace save(tables\Table S5.rtf) title(Solidarity Index - correlations)	
		asdoc factor solidarity_1 solidarity_2 solidarity_3 solidarity_4	[aweight=gewicht3] if filter_1 == 1	, pcf  append save(tables\Table S5.rtf) title(Solidarity Index - exploratory factor analysis)	
		asdoc rotate ,   append save(tables\Table S5.rtf) title(Solidarity Index - rotatated)		
		asdoc estat kmo, append save(tables\Table S5.rtf) title(Solidarity Index - Kaiser-Meyer-Olkin measure of sampling adequacy)
		asdoc alphawgt solidarity_1 solidarity_2 solidarity_3 solidarity_4 [aweight=gewicht3] if filter_1 == 1, item append save(tables\Table S5.rtf) title(Solidarity Index - Cronbachs Alpha)
		
			* alternatively via pca command
			pca solidarity_1 solidarity_2 solidarity_3 solidarity_4	[aweight=gewicht3] if filter_1 == 1
			estat loadings, cnorm(eigen)

	* Big Five --> Supplementary Table 5b)
		asdoc pwcorr big_5_1 - big_5_10 [aweight=gewicht3] if filter_1 == 1	, append save(tables\Table S5.rtf) title(Big Five Index - correlations)
		asdoc factor big_5_1 - big_5_10[aweight=gewicht3] if filter_1 == 1, pf append save(tables\Table S5.rtf) title(Big Five Index - exploratory factor analysis)
		asdoc rotate, append save(tables\Table S5.rtf) title(Big Five Index - rotated)
		asdoc estat kmo, append save(tables\Table S5.rtf) title(Big Five Index - Kaiser-Meyer-Olkin measure of sampling adequacy)
		
		asdoc alphawgt big_5_1_rec big_5_6 [aweight=gewicht3] if filter_1 == 1	, item append save(tables\Table S5.rtf) title(Big Five Index - Cronbachs Alpha)
		asdoc alphawgt big_5_2 big_5_7_rec [aweight=gewicht3] if filter_1 == 1	, item append save(tables\Table S5.rtf) title(Big Five Index - Cronbachs Alpha)
		asdoc alphawgt big_5_3_rec big_5_8 [aweight=gewicht3] if filter_1 == 1	, item append save(tables\Table S5.rtf) title(Big Five Index - Cronbachs Alpha)
		asdoc alphawgt big_5_4_rec big_5_9 [aweight=gewicht3] if filter_1 == 1	, item append save(tables\Table S5.rtf) title(Big Five Index - Cronbachs Alpha)
		asdoc alphawgt big_5_5_rec big_5_10 [aweight=gewicht3] if filter_1 == 1	, item append save(tables\Table S5.rtf) title(Big Five Index - Cronbachs Alpha)




*****************************************************************************************************
***** 						Analyis I - # SARS-CoV-2 immunization doses							*****
*****************************************************************************************************

*** Figure 2 stacked *********

	*reverse order of attitudes variables for figure only
	egen medical_system_1_rev = axis(medical_system_1), label(medical_system_1) reverse
	egen medical_system_2_rev = axis(medical_system_2), label(medical_system_2) reverse
	egen school_system_3_rev = axis(school_system_3), label(school_system_3) reverse

	* Fig 2a
	** vaccination status - by attitude towards homeopathy
	graph bar [aweight = gewicht3],  over(vacc_04) by(medical_system_1_rev , note("")  title("Mainstream medicine") col(1) ) ytitle("") asyvars stack xsize(2) ysize(6) yscale (off)  legend(subtitle("Number of vaccinations received") pos(6) row(1) label(1 "0") label(2 "1") label(3 "2") label(4 "3"  ) label(5 "4" )) ///
		bar(1, fcolor(orange_red) lw(none)) ///
		bar(2, fcolor(blue*.1) lw(none)) ///
		bar(3, fcolor(blue*.4) lw(none)) ///
		bar(4, fcolor(blue*.70) lw(none)) ///
		bar(5, fcolor(blue) lw(none)) ///
		scheme(plottigblind)
		
	graph save "dump\fig_2a.gph", replace

	* Fig 2b
	** vaccination status - by attitude towards homeopathy
	graph bar [aweight = gewicht3], over(vacc_04) by(medical_system_2_rev , note ("") title("Homeopathy") col(1) legend(off)) ytitle("") asyvars stack xsize(2) ysize(6) ///
		bar(1, fcolor(orange_red) lw(none)) ///
		bar(2, fcolor(blue*.1) lw(none)) ///
		bar(3, fcolor(blue*.4) lw(none)) ///
		bar(4, fcolor(blue*.70) lw(none)) ///
		bar(5, fcolor(blue) lw(none)) ///
		scheme(plottigblind)
		
	graph save "dump\fig_2b.gph", replace

	* Fig 2c
	** vaccination status - by attitude towards homeopathy
	graph bar [aweight = gewicht3], over(vacc_04) by(school_system_3_rev , note("") title("Waldorf education") col(1) legend(off)) ytitle("") asyvars stack  xsize(2) ysize(6) ///
		bar(1, fcolor(orange_red) lw(none)) ///
		bar(2, fcolor(blue*.1) lw(none)) ///
		bar(3, fcolor(blue*.4) lw(none)) ///
		bar(4, fcolor(blue*.70) lw(none)) ///
		bar(5, fcolor(blue) lw(none)) ///
		scheme(plottigblind)
			
	graph save "dump\fig_2c.gph", replace

	* Fig 2d
	** vaccination status - by religion
	graph hbar [aweight = gewicht3],  over(vacc_04) by(religion, note("") subtitle("Religious denomination") col(1) ) ytitle("") asyvars stack xsize(2) ysize(5) fxsize(30) legend(subtitle("Number of SARS-CoV-2 vaccine doses received") pos(6) row(1) label(1 "0") label(2 "1") label(3 "2") label(4 "3"  ) label(5 "4" )) ///
		bar(1, fcolor(orange_red) lw(none)) ///
		bar(2, fcolor(blue*.1) lw(none)) ///
		bar(3, fcolor(blue*.4) lw(none)) ///
		bar(4, fcolor(blue*.70) lw(none)) ///
		bar(5, fcolor(blue) lw(none)) ///
		scheme(plottigblind)
			
	graph save "dump\fig_2d.gph", replace

	grc1leg "dump\fig_2c" "dump\fig_2b" "dump\fig_2a" , col(3) xsize(7) ysize(10) scale(.8) title("Attitudes towards...") 
	gr_edit .plotregion1.graph1.legend.draw_view.setstyle, style(no)
	graph save "dump\fig_2_1.gph", replace


	grc1leg "dump\fig_2_1" "dump\fig_2d" , col(2) xsize(7) ysize(10) scale(.8) legendfrom("dump\fig_2d")
	gr_edit .plotregion1.graph1.plotregion1.graph3.legend.draw_view.setstyle, style(no)
	gr_edit .plotregion1.graph2.legend.draw_view.setstyle, style(no)
	gr_edit .plotregion1.graph2.subtitle.style.editstyle color(black) editcopy
	gr_edit .plotregion1.graph2.subtitle.style.editstyle size(small) editcopy
	gr_edit .plotregion1.graph2.plotregion1.subtitle[1].style.editstyle size(vsmall) editcopy
	gr_edit .plotregion1.graph2.plotregion1.scaleaxis[8].style.editstyle majorstyle(tickstyle(textstyle(size(vsmall)))) editcopy
	gr_edit .plotregion1.graph2.b1title.style.editstyle size(vsmall) editcopy
	gr_edit .legend.subtitle.style.editstyle size(vsmall) editcopy
	gr_edit .legend.plotregion1.label[1].style.editstyle size(vsmall) editcopy
	gr_edit .legend.plotregion1.label[2].style.editstyle size(vsmall) editcopy
	gr_edit .legend.plotregion1.label[3].style.editstyle size(vsmall) editcopy
	gr_edit .legend.plotregion1.label[4].style.editstyle size(vsmall) editcopy
	gr_edit .legend.plotregion1.label[5].style.editstyle size(vsmall) editcopy
	gr_edit .style.editstyle aspect_pos(north) editcopy
	gr_edit .style.editstyle declared_ysize(7) editcopy
	gr_edit .style.editstyle boxstyle(shadestyle(color(white))) editcopy
	gr_edit .plotregion1.graph2.AddTextBox added_text editor -.5846108243131736 5.44483432727563
	gr_edit .plotregion1.graph2.added_text_new = 1
	gr_edit .plotregion1.graph2.added_text_rec = 1
	gr_edit .plotregion1.graph2.added_text[1].style.editstyle  angle(default) size(medsmall) color(black) horizontal(left) vertical(middle) margin(zero) linegap(zero) drawbox(no) boxmargin(zero) fillcolor(black) linestyle( width(thin) color(black) pattern(solid) align(inside)) box_alignment(east) editcopy
	gr_edit .plotregion1.graph2.added_text[1].style.editstyle size(vsmall) editcopy
	gr_edit .plotregion1.graph2.added_text[1].text = {}
	gr_edit .plotregion1.graph2.added_text[1].text.Arrpush percent of respondents
	gr_edit .plotregion1.graph2.added_text[1].DragBy .3626079169319681 1.450431667727866
	gr_edit .plotregion1.graph1.AddTextBox added_text editor 48.61324056082995 -.0016739075676973
	gr_edit .plotregion1.graph1.added_text_new = 1
	gr_edit .plotregion1.graph1.added_text_rec = 1
	gr_edit .plotregion1.graph1.added_text[1].style.editstyle  angle(default) size(medsmall) color(black) horizontal(left) vertical(middle) margin(zero) linegap(zero) drawbox(no) boxmargin(zero) fillcolor(black) linestyle( width(thin) color(black) pattern(solid) align(inside)) box_alignment(east) editcopy
	gr_edit .plotregion1.graph1.added_text[1].style.editstyle size(vsmall) editcopy
	gr_edit .plotregion1.graph1.added_text[1]._set_orientation vertical
	gr_edit .plotregion1.graph1.added_text[1].text = {}
	gr_edit .plotregion1.graph1.added_text[1].text.Arrpush percent of respondents
	gr_edit .plotregion1.graph1.added_text[1].DragBy -.0901902071634076 .8987243126825132
	gr_edit .plotregion1.graph1.added_text[1].style.editstyle size(small) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph1.plotregion1.scaleaxis[1].style.editstyle majorstyle(tickstyle(textstyle(size(medsmall)))) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph2.plotregion1.scaleaxis[1].style.editstyle majorstyle(tickstyle(textstyle(size(medsmall)))) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph3.plotregion1.scaleaxis[1].style.editstyle majorstyle(tickstyle(textstyle(size(medsmall)))) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph1.plotregion1.subtitle[1].style.editstyle size(medium) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph2.plotregion1.subtitle[1].style.editstyle size(medium) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph3.plotregion1.subtitle[1].style.editstyle size(medium) editcopy
	gr_edit .plotregion1.graph2.plotregion1.subtitle[1].style.editstyle size(small) editcopy
	gr_edit .plotregion1.graph2.plotregion1.subtitle[1].style.editstyle size(vsmall) editcopy
	gr_edit .plotregion1.graph1.style.editstyle boxstyle(linestyle(color(black))) editcopy
	gr_edit .plotregion1.graph1.style.editstyle boxstyle(linestyle(pattern(dash))) editcopy
	gr_edit .plotregion1.graph1.style.editstyle aspect_pos(north) editcopy
	gr_edit .plotregion1.graph1.style.editstyle aspect_pos(north) editcopy
	gr_edit .plotregion1.graph2.style.editstyle boxstyle(linestyle(color(dknavy))) editcopy
	gr_edit .plotregion1.graph2.style.editstyle boxstyle(linestyle(pattern(dash))) editcopy
	gr_edit .plotregion1.graph1.style.editstyle boxstyle(shadestyle(color(white))) editcopy
	gr_edit .plotregion1.graph2.style.editstyle boxstyle(shadestyle(color(white))) editcopy
	gr_edit .plotregion1.graph1.title.style.editstyle color(black) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph1.title.style.editstyle color(black) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph2.title.style.editstyle color(black) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph3.title.style.editstyle color(black) editcopy
	gr_edit .plotregion1.graph2.plotregion1.move plotregion1[5] on 65 8
	gr_edit .plotregion1.graph2.plotregion1.move plotregion1[7] below 19 8
	gr_edit .plotregion1.graph2.plotregion1.move subtitle[7] below 20 8
	gr_edit .plotregion1.graph2.plotregion1.move plotregion1[6] on 37 8
	gr_edit .plotregion1.graph2.plotregion1.move subtitle[6] below 39 8
	gr_edit .plotregion1.graph2.plotregion1.move plotregion1[5] on 56 8
	gr_edit .plotregion1.graph2.plotregion1.move subtitle[5] on 58 8
	gr_edit .plotregion1.graph2.plotregion1.move subtitle[2] leftof 128 8
	gr_edit .plotregion1.graph2.plotregion1.move subtitle[2] on 128 9
	gr_edit .plotregion1.graph2.plotregion1.move subtitle[3] on 110 9
	gr_edit .plotregion1.graph2.plotregion1.move subtitle[4] on 92 9
	gr_edit .plotregion1.graph2.plotregion1.move plotregion1[5] below 56 9
	gr_edit .plotregion1.graph2.plotregion1.move subtitle[5] on 57 9
	gr_edit .plotregion1.graph2.plotregion1.AddTextBox added_text editor 49 1.357587771475336
	gr_edit .plotregion1.graph2.plotregion1.added_text_new = 1
	gr_edit .plotregion1.graph2.plotregion1.added_text_rec = 1
	gr_edit .plotregion1.graph2.plotregion1.added_text[1].style.editstyle  angle(default) size(medsmall) color(black) horizontal(left) vertical(middle) margin(zero) linegap(zero) drawbox(no) boxmargin(zero) fillcolor(black) linestyle( width(thin) color(black) pattern(solid) align(inside)) box_alignment(east) editcopy
	gr_edit .plotregion1.graph2.plotregion1.added_text[1].text = {}
	gr_edit .plotregion1.graph2.plotregion1.added_text[1].text.Arrpush Denominations below represent 3% of sample 
	gr_edit .plotregion1.graph2.plotregion1.added_text[1].style.editstyle size(small) editcopy
	gr_edit .plotregion1.graph2.plotregion1.added_text[1].DragBy -.8823366812036142 0
	gr_edit .plotregion1.graph2.plotregion1.added_text[1].DragBy .551460425752239 5.294020087221785
	gr_edit .plotregion1.graph2.plotregion1.added_text[1].DragBy .110292085150468 1.544089192106306
	gr_edit .plotregion1.graph2.plotregion1.added_text[1].DragBy -.110292085150468 -7
	gr_edit .plotregion1.graph1.plotregion1.graph2.plotregion1.scaleaxis[1].style.editstyle majorstyle(tickstyle(textstyle(color(white)))) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph2.plotregion1.scaleaxis[1].style.editstyle majorstyle(use_labels(no)) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph2.plotregion1.scaleaxis[1].style.editstyle majorstyle(alternate(no)) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph2.plotregion1.scaleaxis[1].style.editstyle majorstyle(tickstyle(linestyle(color(white)))) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph2.plotregion1.scaleaxis[1].style.editstyle linestyle(color(white)) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph3.plotregion1.scaleaxis[1].style.editstyle majorstyle(tickstyle(textstyle(color(white)))) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph3.plotregion1.scaleaxis[1].style.editstyle majorstyle(use_labels(no)) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph3.plotregion1.scaleaxis[1].style.editstyle majorstyle(alternate(no)) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph3.plotregion1.scaleaxis[1].style.editstyle majorstyle(tickstyle(linestyle(color(white)))) editcopy
	gr_edit .plotregion1.graph1.plotregion1.graph3.plotregion1.scaleaxis[1].style.editstyle linestyle(color(white)) editcopy
	graph export "fig\Figure 2.emf", replace
	graph export "fig\Figure 2.pdf", replace

* Main Model OLS
* M1: Mainstream medicine, Homeopathy and Waldorf_school
reg vacc_04 school_system_3 medical_system_2 medical_system_1  b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc [pweight=gewicht3] if filter_1 == 1
est store m1_1

* M2: religion
reg vacc_04 i.religion  b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc [pweight=gewicht3] if filter_1 == 1
est store m1_2

* M3: political factors
reg vacc_04 left_right GAL_TAN i.sonntagsfrage b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc [pweight=gewicht3] if filter_1 == 1
est store m1_3

* M4: psychological factors
reg vacc_04 solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc [pweight=gewicht3] if filter_1 == 1
est store m1_4

	* stepwise models
	* M1a: + Religion + Big 5
	reg vacc_04 school_system_3 medical_system_2 medical_system_1  b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc i.religion big_5_a big_5_c big_5_e big_5_n big_5_o  [pweight=gewicht3] if filter_1 == 1
	est store m1_1a

	* M1b: + left_right
	reg vacc_04 school_system_3 medical_system_2 medical_system_1  b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc i.religion big_5_a big_5_c big_5_e big_5_n big_5_o left_right [pweight=gewicht3] if filter_1 == 1
	est store m1_1b

	* M1c: + GAL_TAN
	reg vacc_04 school_system_3 medical_system_2 medical_system_1  b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc i.religion big_5_a big_5_c big_5_e big_5_n big_5_o GAL_TAN [pweight=gewicht3] if filter_1 == 1
	est store m1_1c

	* M1d: + Sonntagsfrage
	reg vacc_04 school_system_3 medical_system_2 medical_system_1  b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc i.religion big_5_a big_5_c big_5_e big_5_n big_5_o i.sonntagsfrage  [pweight=gewicht3] if filter_1 == 1
	est store m1_1d

	* M1e: + solidarity index
	reg vacc_04 school_system_3 medical_system_2 medical_system_1  b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc i.religion big_5_a big_5_c big_5_e big_5_n big_5_o solidarity_index [pweight=gewicht3] if filter_1 == 1
	est store m1_1e

pwcorr school_system_3 left_right GAL_TAN solidarity_index [aweight=gewicht3] if filter_1 == 1

* M5: full model
reg  vacc_04 school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_1 == 1
est store m1_5
margins, at(school_system_3=(0(0.25)1)) saving("dump\waldorf_1", replace) 
marginsplot, title("Linear regression")  ysize(6) xsize(6)
graph save "dump\fig_S4a.gph", replace

margins, at(medical_system_2=(0(0.25)1)) saving("dump\homeopathy_1", replace) 
marginsplot, title("Linear regression")  ysize(6) xsize(6)
graph save "dump\fig_S4c.gph", replace

margins, at(medical_system_1=(0(0.25)1)) saving("dump\mainstream_1", replace) 
marginsplot, title("Linear regression")  ysize(6) xsize(6)
graph save "dump\fig_S4e.gph", replace

*** Figure S4: crosscheck with Poisson regression
poisson  vacc_04 school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_1 == 1 
estat gof
margins, at(school_system_3=(0(0.25)1)) saving("dump\waldorf_2", replace)
marginsplot, title("Poisson regression")  ysize(6) xsize(6)
graph save "dump\fig_S4b.gph", replace

margins, at(medical_system_2=(0(0.25)1)) saving("dump\homeopathy_2", replace) 
marginsplot, title("Poisson regression")  ysize(6) xsize(6)
graph save "dump\fig_S4d.gph", replace

margins, at(medical_system_1=(0(0.25)1)) saving("dump\mainstream_2", replace) 
marginsplot, title("Poisson regression")  ysize(6) xsize(6)
graph save "dump\fig_S4f.gph", replace

combomarginsplot12 "dump\waldorf_1" "dump\waldorf_2", labels("Linear regression" "Poisson regression") ytitle("Predicted number of SARS-CoV-2 vaccine doses") title("Waldorf education") xtitle("")
graph save "dump\fig_S4_1.gph", replace

combomarginsplot12 "dump\homeopathy_1" "dump\homeopathy_2", labels("Linear regression" "Poisson regression") ytitle("Predicted number of SARS-CoV-2 vaccine doses") title("Homeopathy") xtitle("")
graph save "dump\fig_S4_2.gph", replace

combomarginsplot12 "dump\mainstream_1" "dump\mainstream_2", labels("Linear regression" "Poisson regression") ytitle("Predicted number of SARS-CoV-2 vaccine doses") title("Mainstream medicine") xtitle("")
graph save "dump\fig_S4_3.gph", replace

grc1leg2 "dump\fig_S4_1.gph" "dump\fig_S4_2.gph" "dump\fig_S4_3.gph", col(2) xsize(5) ysize(5) scale(0.7)
graph export "fig\Figure S4.pdf", replace
graph export "fig\Figure S4.emf", replace



* Interactions

*** Figure S1: Estimated number of SARS-CoV-2 vaccine doses by attitudes towards Waldorf education, homeopathy and mainstream medicine over age group and gender (+ 95% CI)
* Interaction: x age
reg  vacc_04 c.medical_system_1##i.age_group_r c.medical_system_2##i.age_group_r c.school_system_3##i.age_group_r i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_1 == 1
est store m1_int_1
margins age_group_r, at(medical_system_1=(0(.25)1))
marginsplot, ytitle("") title ("") xtitle("Mainstream medicine") legend(pos(6) col(4)) xlabel(0 "--" 0.25 "-" 0.5 "-/+" 0.75 "+" 1 "++") plot1(msymbol(D)) plot2(msymbol(S)) plot3(msymbol(O)) plot4(msymbol(T)) scheme(plottigblind) 
graph save "dump\fig_S1a.gph", replace

margins age_group_r, at(medical_system_2=(0(.25)1))
marginsplot, ytitle("") title ("")  legend(pos(6) col(4)) xlabel(0 "--" 0.25 "-" 0.5 "-/+" 0.75 "+" 1 "++") plot1(msymbol(D)) plot2(msymbol(S)) plot3(msymbol(O)) plot4(msymbol(T)) scheme(plottigblind) 
graph save "dump\fig_S1b.gph", replace

margins age_group_r, at(school_system_3=(0(.25)1))
marginsplot, ytitle("") title ("")  legend(pos(6) col(4)) xlabel(0 "--" 0.25 "-" 0.5 "-/+" 0.75 "+" 1 "++") plot1(msymbol(D)) plot2(msymbol(S)) plot3(msymbol(O)) plot4(msymbol(T)) scheme(plottigblind) 
graph save "dump\fig_S1c.gph", replace

grc1leg "dump\fig_S1c.gph"  "dump\fig_S1b.gph" "dump\fig_S1a.gph", col(3) ycommon
graph save "dump\fig_S1_a.gph", replace

* Interaction: x gender
reg  vacc_04 c.medical_system_1##i.gender c.medical_system_2##i.gender c.school_system_3##i.gender i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_1 == 1
est store m1_int_2
margins gender if gender < 3, at(medical_system_1=(0(.25)1))
marginsplot, ytitle("") title ("") xtitle("Mainstream medicine") legend(pos(6) col(4)) xlabel(0 "--" 0.25 "-" 0.5 "-/+" 0.75 "+" 1 "++") plot1(msymbol(Dh)) plot2(msymbol(Sh)) scheme(plottigblind)
graph save "dump\fig_S1aa.gph", replace

margins gender if gender < 3, at(medical_system_2=(0(.25)1))
marginsplot, ytitle("") title ("")  legend(pos(6) col(4)) xlabel(0 "--" 0.25 "-" 0.5 "-/+" 0.75 "+" 1 "++") plot1(msymbol(Dh)) plot2(msymbol(Sh)) scheme(plottigblind)
graph save "dump\fig_S1bb.gph", replace

margins gender if gender < 3, at(school_system_3=(0(.25)1))
marginsplot, ytitle("") title ("")  legend(pos(6) col(4)) xlabel(0 "--" 0.25 "-" 0.5 "-/+" 0.75 "+" 1 "++") plot1(msymbol(Dh)) plot2(msymbol(Sh)) scheme(plottigblind)
graph save "dump\fig_S1cc.gph", replace

grc1leg "dump\fig_S1cc.gph"  "dump\fig_S1bb.gph" "dump\fig_S1aa.gph", col(3) ycommon
graph save "dump\fig_S1_b.gph", replace

graph combine "dump\fig_S1_a.gph" "dump\fig_S1_b.gph", col(1)  graphregion(margin(zero)) xsize(6) ysize(5)
gr_edit .plotregion1.graph1.AddTextBox added_text editor 30.03597997333353 -.7173341963082758
gr_edit .plotregion1.graph1.added_text_new = 1
gr_edit .plotregion1.graph1.added_text_rec = 1
gr_edit .plotregion1.graph1.added_text[1].style.editstyle  angle(default) size(medsmall) color(black) horizontal(left) vertical(middle) margin(zero) linegap(zero) drawbox(no) boxmargin(zero) fillcolor(black) linestyle( width(thin) color(black) pattern(solid) align(inside)) box_alignment(east) editcopy
gr_edit .plotregion1.graph1.added_text[1].style.editstyle size(vsmall) editcopy
gr_edit .plotregion1.graph1.added_text[1]._set_orientation vertical
gr_edit .plotregion1.graph1.added_text[1].text = {}
gr_edit .plotregion1.graph1.added_text[1].text.Arrpush Estimated number of doses
gr_edit .plotregion1.graph2.AddTextBox added_text editor 27.96213926721225 -.4064455950777011
gr_edit .plotregion1.graph2.added_text_new = 1
gr_edit .plotregion1.graph2.added_text_rec = 1
gr_edit .plotregion1.graph2.added_text[1].style.editstyle  angle(default) size(medsmall) color(black) horizontal(left) vertical(middle) margin(zero) linegap(zero) drawbox(no) boxmargin(zero) fillcolor(black) linestyle( width(thin) color(black) pattern(solid) align(inside)) box_alignment(east) editcopy
gr_edit .plotregion1.graph2.added_text[1].style.editstyle size(vsmall) editcopy
gr_edit .plotregion1.graph2.added_text[1]._set_orientation vertical
gr_edit .plotregion1.graph2.added_text[1].text = {}
gr_edit .plotregion1.graph2.added_text[1].text.Arrpush Estimated number of doses
gr_edit .plotregion1.graph1.added_text[1].DragBy .6994993527688075 1.554443006152874
gr_edit .plotregion1.graph2.added_text[1].DragBy 1.010387953999371 1.010387953999369
gr_edit .plotregion1.graph1.style.editstyle boxstyle(shadestyle(color(white))) editcopy
gr_edit .plotregion1.graph2.style.editstyle boxstyle(shadestyle(color(white))) editcopy
gr_edit .style.editstyle boxstyle(shadestyle(color(white))) editcopy
gr_edit .plotregion1.graph1.style.editstyle boxstyle(linestyle(color(white))) editcopy
gr_edit .plotregion1.graph2.style.editstyle boxstyle(linestyle(color(white))) editcopy

graph export "fig\Figure S1.pdf", replace
graph export "fig\Figure S1.emf", replace

* Figure S2: Average Marginal Effect of attitudes towards Waldorf schools, homeopathy and mainstream medicine on the number of SARS-CoV-2 vaccine doses by state (+ 95% CI)
* Interaction: x bundesland
reg  vacc_04 c.medical_system_1##i.bundesland c.medical_system_2##i.bundesland c.school_system_3##i.bundesland i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_1 == 1
est store m1_int_3

margins if bundesland <17, dydx(medical_system_1 medical_system_2 school_system_3) over(bundesland) 
*marginsplot, horizontal unique xline(0) recast(scatter) legend(pos(6))
mplotoffset, horizontal unique xline(0) recast(scatter) recastci(rspike) level(95) legend(pos(6) col(3) ///
order(6 "Waldorf education" 5 "Homeopathy" 4 "Mainstream medicine") ///
textwidth(*7) span keygap(1.5)) offset(0.15) ytitle("") title("") xtitle("Average Marginal Effect of ...") ///
yscale(reverse) xsize(5) ysize(8) ylabel(,labsize(vsmall)) ///
scheme(plottigblind) 
gr_edit .legend.plotregion1.label[2].DragBy 0 7.25
gr_edit .legend.plotregion1.key[2].DragBy 0 7.25
gr_edit .legend.plotregion1.label[1].DragBy 0 9
gr_edit .legend.plotregion1.key[1].DragBy 0 9

graph export "fig\Figure S2.pdf", replace
graph export "fig\Figure S2.emf", replace


* Crosscheck ologit - not presented
	* M1: political factors
	ologit vacc_04 left_right GAL_TAN i.sonntagsfrage b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc [pweight=gewicht] if filter_1 == 1
	est store ologit1

	* M2: psychological factors
	ologit vacc_04 solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc [pweight=gewicht] if filter_1 == 1
	est store ologit2

	* M3: Mainstream medicine, Homeopathy and Waldorf_education
	ologit vacc_04 medical_system_1 medical_system_2 school_system_3  b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc [pweight=gewicht] if filter_1 == 1
	est store ologit3

	* M4: religion
	ologit vacc_04 i.religion  b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc [pweight=gewicht] if filter_1 == 1
	est store ologit4

	* M5: full model
	ologit  vacc_04 medical_system_1 medical_system_2 school_system_3 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_1== 1
	est store ologit5

	* Table: Ordinal Logit Croscheck 
	esttab ologit1 ologit2 ologit3 ologit4 ologit5 using "dump\crosscheck_ologit_Analysis_I.rtf", label replace eform

	
* Table 3: Analysis I - OLS Regression explaining SARS-CoV-2 vaccine uptake (b-coefficients)
esttab m1_1 m1_2 m1_3 m1_4 m1_5 using "tables\Table 3.rtf",  keep(school_system_3 medical_system_2 medical_system_1 1.religion 2.religion 3.religion 4.religion 5.religion 6.religion 7.religion 8.religion left_right GAL_TAN 1.sonntagsfrage 2.sonntagsfrage 3.sonntagsfrage 4.sonntagsfrage 5.sonntagsfrage 6.sonntagsfrage 7.sonntagsfrage solidarity_index big_5_agreeableness big_5_conscientiousness big_5_extraversion big_5_neuroticism big_5_openness _cons) label ci replace stats(N r2_a)	

* Table S7: Analysis I – Impact on SARS-CoV-2 vaccine uptake (unstandardized b-coefficients from multiple linear regression): separate models by groups of variables (models M1-M4) and full model (M5); 
*			complete regression table presenting also controls for state, gender, age group, education level and household income 
esttab m1_1 m1_2 m1_3 m1_4 m1_5 using "tables\Table S7.rtf",   label ci replace stats(N r2_a)	

* Table S8: Analysis I crosscheck – Impact on SARS-CoV-2 vaccine uptake (unstandardized b-coefficients from stepwise multiple linear regression) 
esttab m1_1a m1_1b m1_1c m1_1d m1_1e m1_5   using "tables\Table S8.rtf", keep(school_system_3 medical_system_2 medical_system_1 left_right GAL_TAN solidarity_index 1.sonntagsfrage 2.sonntagsfrage 3.sonntagsfrage 4.sonntagsfrage 5.sonntagsfrage 6.sonntagsfrage 7.sonntagsfrage _cons) label ci replace stats(N r2_a p)


* Crosscheck basic immunization (binary Logit)
	* M1: Mainstream medicine, Homeopathy and Waldorf_education
	logit basic_vacc school_system_3 medical_system_2 medical_system_1  b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc [pweight=gewicht] if filter_1 == 1
	est store logit_m1_1

	* M2: religion
	logit basic_vacc i.religion  b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc [pweight=gewicht] if filter_1 == 1
	est store logit_m1_2

	* M3: political factors
	logit basic_vacc left_right GAL_TAN i.sonntagsfrage b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc [pweight=gewicht] if filter_1 == 1
	est store logit_m1_3

	* M4: psychological factors
	logit basic_vacc solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o b10.bundesland i.gender  i.age_group_r i.edu_3 i.hh_inc [pweight=gewicht] if filter_1 == 1
	est store logit_m1_4

	* M5: full model
	logit basic_vacc school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_1 == 1
	est store logit_m1_5


* Table S9: Analysis I crosscheck – Binary logistic regression explaining whether a participant has received at least basic SARS-CoV-2 immunization (odds ratios) 
esttab logit_m1_1 logit_m1_2 logit_m1_3 logit_m1_4 logit_m1_5 using "tables\Table S9.rtf", eform label ci replace stats(N r2_p aic)

* Table S10: Analysis I – interaction models (unstandardized b-coefficients from multiple linear regression)
esttab m1_int_1 m1_int_2 m1_int_3  using "tables\Table S10.rtf", label ci replace stats(N r2_a p)





*****************************************************************************************************
***** 			Analyis II - Drivers of SARS- CoV-2 immunization decisions						*****
*****************************************************************************************************

**** Regression explaining reasons
reg vacc_reason_1  school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_2 == 1
estimates store m2a

reg vacc_reason_2  school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_2 == 1
estimates store m2b

reg vacc_reason_5  school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_2 == 1
estimates store m2c

reg vacc_reason_3  school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_2 == 1
estimates store m2d

reg vacc_reason_4  school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_2 == 1
estimates store m2e

reg vacc_reason_6  school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_2 == 1
estimates store m2f

* Figure 3
coefplot (m2a, msymbol(D) label(Protecting self))   ///
         (m2b, msymbol(T) label(Protecting others))    ///
		 (m2c, msymbol(S) label(Medical advice)), bylabel(Voluntary considerations)  ///
		 || (m2d, msymbol(Dh) label(Participation in public events))  ///
         (m2e, msymbol(Th) label(Vocational mandates))  ///
		 (m2f, msymbol(Sh) label(Peer pressure)), bylabel(External pressures) ///		 
         || , msize(small) ///
		 scheme(plottigblind) ///
mlabel(cond(@pval<.001, "***", ///
cond(@pval<.01, "**", ///
cond(@pval<.05, "*", ///
cond(@pval>.05, "", ///
string(@pval,"%9.3f")))))) ///
mlabposition(3) mlabgap() mlabsize(medium) /// 
drop(_cons) keep(school_system_3  medical_system_2 medical_system_1 2.religion 3.religion 4.religion left_right GAL_TAN *.sonntagsfrage solidarity_index big_5_agreeableness big_5_conscientiousness big_5_extraversion big_5_neuroticism big_5_openness  ) xline(0) msymbol(S) norecycle levels(95) ///
		 headings(school_system_3 = "{bf:Positive attitudes towards...}" 2.religion = "{bf:Religion (ref: no denomination)}" left_right = "{bf:Political ideology}" 2.sonntagsfrage = "{bf: Party affiliation (ref: CDU/CSU)}" solidarity_index = "{bf: Psychological traits}") xsize(7) ysize(10) legend(title("Dependent variable:", color(black)) subtitle("Importance of ... ", size(small)) note("... for the decision to get vaccinated against SARS-CoV-2." "Scale: 0–1; 0 = 'not at all important', 1 = 'very important'")   order (2 8 4 10 6 12) col(2) colgap(20) keygap(2) ) 
gr_edit .gmetric_mult = .62
gr_edit .legend.caption.DragBy -1.511189090267205 -.215884155752458
gr_edit .legend.subtitle.DragBy -.1541069502234547 -28.04746494066881
// subtitle reposition

gr_edit .legend.note.DragBy 0 -4.469101556480196
// note reposition

gr_edit .legend.subtitle.DragBy .3082139004469114 -.4623208506703603
// subtitle reposition

gr_edit .legend.note.DragBy -.7705347511172714 -.1541069502234547
// note reposition
graph export "fig\Figure 3.emf", replace
graph export "fig\Figure 3.pdf", replace

* crosscheck Ologit
**** Regression explaining reasons
ologit vacc_reason_1  school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_2 == 1
estimates store m2a_ologit

ologit vacc_reason_2  school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_2 == 1
estimates store m2b_ologit

ologit vacc_reason_5  school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_2 == 1
estimates store m2c_ologit

ologit vacc_reason_3  school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_2 == 1
estimates store m2d_ologit

ologit vacc_reason_4  school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_2 == 1
estimates store m2e_ologit

ologit vacc_reason_6  school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_2 == 1
estimates store m2f_ologit

* Table S11: Analysis II – Impact on the self-perceived relative importance of six concrete reasons for SARS-CoV-2 immunization decisions (unstandardized b-coefficients from multiple linear regression)
esttab m2a m2b m2c m2d m2e m2f using "tables\Table S11.rtf", label ci replace stats(N r2_a p)


* Table S12: Analysis II crosscheck – Ordinal logistic regression explaining the level of self-perceived relative importance of six concrete reasons for SARS-CoV-2 immunization decisions (odds ratios)
esttab m2a_ologit m2b_ologit m2c_ologit m2d_ologit m2e_ologit m2f_ologit  using "tables\Table S12.rtf", label ci replace stats(N r2_p aic) eform


*****************************************************************************************************
***** 				Analyis III - Attitudes towards routine pediatric imunization (MMR)			*****
*****************************************************************************************************


* rescale vacc_04 to 0-1 in order to make it comparable to child_vaccination
gen vacc_04_rescale = vacc_04/4

* M1.5: full model - with rescaled vacc_04_rescale
reg  vacc_04_rescale school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_1 == 1
est store m1_5_rescale

* M3_MMR full model - with attitudes towards routine pedatric immunization (MMR) as dependent variable
* Figure 4
reg  child_vaccinations school_system_3 medical_system_2 medical_system_1 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_1 == 1
estimates store m3
coefplot (m1_5_rescale,  label("SARS-CoV-2 vaccine uptake" "Scale: 0–1 (0 = 'unvaccinated', 0.25 = '1 dose', 0.5 = '2 doses', 0.75 = '3 doses', 1 = '4 doses')")), bylabel(SARS-CoV-2 vaccine uptake) ///
		|| (m3,  label("How useful do you consider routine pediatric immunization (MMR)?" "Scale: 0–1  (0 = 'not at all meaningful', 0.33 = 'rather not meaningful', 0.67 = 'rather meaningful', 1 = 'very meaningful')" ) ), bylabel(Routine pediatric immunization (MMR)) ///
		||, drop(_cons) xline(0) scale(0.5) headings(left_right = "{bf:Political ideology}" school_system_3 = "{bf:Positive attitudes towards...}" 2.gender = "{bf:Gender (ref: male)}" 2.age_group_raking = "{bf:Age group (ref: 18-30)}" 2.sonntagsfrage = "{bf: Party affiliation (ref: CDU/CSU)}" solidarity_index = "{bf: Psychological traits}" 2.edu_3 = "{bf:Education-Level (ref: low)}" 1.bundesland = "{bf:State (ref: NRW)}" 2.religion = "{bf: Religion (ref: no denomination)}" 2.hh_income = `""{bf:Household income}" "{bf:(ref: I find it very difficult to make ends meet)}""' )	xsize(10) ysize(12) levels(95) legend(col(1) subtitle("Dependent variable:"))	norecycle msize(small) ///
scheme(plottigblind)  ///
		mlabel(cond(@pval<.001, "***", ///
cond(@pval<.01, "**", ///
cond(@pval<.05, "*", ///
cond(@pval>.05, "", ///
string(@pval,"%9.3f")))))) ///
mlabposition(3) mlabgap() mlabsize(medium) 
gr_edit .gmetric_mult = .5
graph export "fig\Figure 4.pdf", replace
graph export "fig\Figure 4.emf", replace

* crosscheck ologit
ologit  child_vaccinations medical_system_1 medical_system_2 school_system_3 i.religion left_right GAL_TAN i.sonntagsfrage solidarity_index big_5_a big_5_c big_5_e big_5_n big_5_o  b10.bundesland i.gender i.age_group_r i.edu_3 i.hh_inc  [pweight = gewicht3] if filter_1 == 1
estimates store m3_ologit

* Table S13: Analysis III – Comparison between the impact on SARS-CoV-2 vaccine uptake and the impact on views towards routine pediatric immunization (MMR) 
* 			(unstandardized b-coefficients from multiple linear regression + odds ratios from crosscheck with ordinal logistic regression)
esttab m1_5_rescale m3   using "tables\Table S13a.rtf",  label ci replace stats(N r2_a r2_p aic)
esttab  m3_ologit  using "tables\Table S13b.rtf", eform label ci replace stats(N r2_a r2_p aic)









